<%-- 
    Document   : ValidasiLogin
    Created on : Jun 8, 2013, 12:09:57 PM
    Author     : Florencia
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <title>Proses Page</title>
    </head>
    <body background = "../gambar/background2.jpg" style = "background-repeat: no-repeat; background-attachment: fixed">
        <jsp:useBean id="user" scope="session" class="bean.User" />
        <%
                    String name = request.getParameter("userName");
                    String password = request.getParameter("password");


                    user.setUserName(name);
                    user.setPassword(password);

                    if (user.isUserNameValid(user.getUserName()) && user.isPasswordValid(user.getPassword())) {
        %>

        <div align="center">
            <center><table border = 10 cellpadding = 10 cellspacing = 3 bgcolor="#FFFFFF">
                    <tr>
                        <td colspan="4" bgcolor = "#FFFFFF">
                            <center><font color = "brown" size = "7">
                                    <b>THE BIGGEST FASHION SHOP</b></font>
                            </center>
                    </tr>
                    <tr bgcolor="#FFFFFF">
                    <center><th>
                            <img src="../gambar/cover1.jpg" width="300" height="350">
                        </th>
                        <td>
                            <img src="../gambar/cover2.jpg" width="300" height="350">
                        </td>
                        <td>
                            <img src="../gambar/cover3.jpg" width="300" height="350">
                        </td>
                        <td>
                            <img src="../gambar/cover4.jpg" width="300" height="350">
                        </td>
                    </center>
                    </tr>
                    <tr>
                        <td colspan="4" bgcolor = "#FFFFFF">
                    <marquee>
                        <center><font color = "brown" size = "7">
                                <b>KAMI BUKAN YANG PERTAMA, TAPI YANG UTAMA</b></font>
                        </center>
                    </marquee>
                    </td>
                    </tr>
                </table></center>
        </div>

        <br><br>

        <ul>
            <li><font size = "7"><a href="Search.jsp" class="selected" style="text-decoration:none">Cari Transaksi</a></font></li>
            <li><font size = "7"><a href="Lihat.jsp" style="text-decoration:none">Lihat Transaksi</a></font></li>
            <li><font size = "7"><a href="DeleteTransaksi.jsp" style="text-decoration:none">Delete Transaksi</a></font></li>
        </ul>

        <center><form action="loginAdmin.jsp">
            <b><font size = "6">Untuk keluar silahkan klik di sini : </font></b>
            <input type="submit" name ="submit" value="Logout" />
        </form></center>


        <%        } else {
        %>
        <center><b>
                <br><br><br><br>
                <font size = "6">MAAF, Username dan Password yang anda masukkan salah !!</font><br><br>
                <ul>
                    <li><font size = "5"><a href="loginAdmin.jsp" style="text-decoration:none">Coba lagi?</a></font></li>
                    <br>
                    <li><font size = "5"><a href="../index.jsp" style="text-decoration:none">Kembali ke Menu Utama</a></font></li>
                </ul>
            </b></center>
            <%  }%>

    </body>
</html>